﻿<%@ Page Title="demandplaninfo" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeBehind="List.aspx.cs" Inherits="lcs.Web.demandplaninfo.List" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script language="javascript" src="/js/CheckBox.js" type="text/javascript"></script>
     <script type="text/javascript">

         function OpenPop(val, w, h) {
             if (true == window.showModalDialog(val, window.self, "dialogwidth=" + w + ";dialogheight=" + h + ";" + " resizable:yes;")) {
                 __doPostBack('btn_reload', 'btn_reload_Click');
             }

         }

         function OpenPopWin(val, w, h) {
             //window.showModalDialog(val,window.self,"dialogwidth="+w+";dialogheight="+h+";")

             window.open(val, 'newwindow', "height=" + h + ",width=" + w + ",toolbar=yes,scrollbars=yes,resizable=yes");
         }

    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">

    <table style="width: 100%;" cellpadding="2" cellspacing="1" class="border">
        <tr>
            <td style="width: 80px" align="right" class="tdbg">
                <b>计划编号：</b>
            </td>
            <td class="tdbg" style="text-align: left;">
                <asp:TextBox ID="txtKeyword" runat="server"></asp:TextBox>
                &nbsp;&nbsp;&nbsp;&nbsp;
                    <asp:Button ID="btnSearch" runat="server" Text="查询" OnClick="btnSearch_Click"></asp:Button>

            </td>
            <td class="tdbg">
                <input class ="btn" type="button" value ="增加" onclick="location.href='Add.aspx'"/>
            </td>
        </tr>
    </table>
    <!--Search end-->
    <br />
    <asp:GridView ID="gridView" runat="server" AllowPaging="True" Width="100%" BorderWidth="0px" CellPadding="0" CellSpacing="1" CssClass="gv" GridLines="None" OnPageIndexChanging="gridView_PageIndexChanging"
        DataKeyNames="dpid" OnRowDataBound="gridView_RowDataBound"
        AutoGenerateColumns="False" RowStyle-HorizontalAlign="Center" OnRowCreated="gridView_OnRowCreated" OnRowDeleting="gridView_RowDeleting" OnRowCommand="gridView_RowCommand">
        <Columns>
            <%--		<asp:BoundField DataField="npmethod" HeaderText="拟采购方式:（招标/单一/应用" SortExpression="npmethod" ItemStyle-HorizontalAlign="Center"  /> 
		<asp:BoundField DataField="fundsource" HeaderText="资金来源" SortExpression="fundsource" ItemStyle-HorizontalAlign="Center"  /> --%>
            <%--		<asp:BoundField DataField="ordernum" HeaderText="采购订单号" SortExpression="ordernum" ItemStyle-HorizontalAlign="Center"  /> 
		<asp:BoundField DataField="paymethod" HeaderText="付款方式" SortExpression="paymethod" ItemStyle-HorizontalAlign="Center"  /> 
		<asp:BoundField DataField="signtime" HeaderText="合同签订日期" SortExpression="signtime" ItemStyle-HorizontalAlign="Center"  /> 
		<asp:BoundField DataField="batchnum" HeaderText="批次编号" SortExpression="batchnum" ItemStyle-HorizontalAlign="Center"  /> 
		<asp:BoundField DataField="bagnum" HeaderText="包号" SortExpression="bagnum" ItemStyle-HorizontalAlign="Center"  /> 
		<asp:BoundField DataField="scorefile" HeaderText="评分标准" SortExpression="scorefile" ItemStyle-HorizontalAlign="Center"  /> 
		<asp:BoundField DataField="tendertime" HeaderText="拟招标日期" SortExpression="tendertime" ItemStyle-HorizontalAlign="Center"  /> --%>

            <asp:TemplateField ControlStyle-Width="30" HeaderText="选择">
                <HeaderTemplate>
                    <input id="Checkbox1" type="checkbox" onclick="javascript: chall(this)" />
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:CheckBox ID="DeleteThis" runat="server" />
                </ItemTemplate>

                <ControlStyle Width="30px"></ControlStyle>
            </asp:TemplateField>

            <asp:TemplateField HeaderText="查看" HeaderStyle-Wrap="false">
                <ItemTemplate>
                    <asp:HyperLink ID="hy_look" runat="server" ForeColor="Blue" NavigateUrl='<%# Eval("dpid", "../../DemandPlan/DemandPlanSubmit.aspx?id={0}&type=check") %>' Text="查看"></asp:HyperLink>
                </ItemTemplate>
            </asp:TemplateField>

            <asp:TemplateField HeaderText="操作">
                <ItemTemplate>
                    <asp:HyperLink ID="hy_submit" runat="server" ForeColor="Blue" NavigateUrl='<%# Eval("dpid", "../../DemandPlan/DemandPlanSubmit.aspx?id={0}") %>' Text="提交审核"></asp:HyperLink>
                   <%-- <asp:HyperLink ID="hy_print" runat="server" ForeColor="Blue" NavigateUrl='<%# Eval("dpid", "../../DemandPlan/PrintDemandPlan.aspx?id={0}") %>' Text="打印"></asp:HyperLink>--%>
                    <asp:LinkButton ID="hy_print" runat="server" ForeColor="Blue" CommandName="print" CommandArgument='<%# Bind("dpid") %>'>打印</asp:LinkButton>
                    <asp:HyperLink ID="hy_wlgl" runat="server" ForeColor="Blue" Text="物料管理"></asp:HyperLink>
                    <asp:Label ID="lbl_dpid" runat="server" Text='<%# Bind("dpid") %>' Visible="false"></asp:Label>
                    <asp:Label ID="lbl_type" runat="server" Text='<%# Bind("ptype") %>' Visible="false"></asp:Label>
                   
                </ItemTemplate>

            </asp:TemplateField>

            <asp:TemplateField HeaderText="状态" SortExpression="status">
              
                <ItemTemplate>
                   <asp:Label ID="lbl_warn" runat="server" Text=''></asp:Label>
                </ItemTemplate>
                <ItemStyle HorizontalAlign="Center" />
            </asp:TemplateField>

            <asp:TemplateField HeaderText="技术文件" SortExpression="skillfile">
                <ItemTemplate>
                    <asp:HyperLink ID="hlsfile" runat="server" NavigateUrl='<%# Bind("skillfile") %>' ForeColor="Blue">下载</asp:HyperLink>
                </ItemTemplate>
                <ItemStyle HorizontalAlign="Center" />
            </asp:TemplateField>

            <asp:BoundField DataField="pbh" HeaderText="计划编号" SortExpression="pbh" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:BoundField DataField="proid" HeaderText="项目编号" SortExpression="proid" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:TemplateField HeaderText="项目名称">                            
                            <ItemTemplate>
                                <asp:Label ID="Label1" runat="server" Text='<%# Decode(Eval("projectname").ToString()) %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
            <asp:BoundField DataField="user_name" HeaderText="提交人" SortExpression="user_name" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:BoundField DataField="pmtype" HeaderText="采购类别" SortExpression="pmtype" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:BoundField DataField="inputtime" HeaderText="提交时间" SortExpression="inputtime" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:BoundField DataField="invoicetype" HeaderText="需开具发票类型" SortExpression="invoicetype" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:BoundField DataField="sname" HeaderText="应用类推荐厂家" SortExpression="sname" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:BoundField DataField="mtname" HeaderText="协议物料类别" SortExpression="mtsname" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:BoundField DataField="xysname" HeaderText="协议供应商" SortExpression="xysname" ItemStyle-HorizontalAlign="Center">
                <ItemStyle HorizontalAlign="Center"></ItemStyle>
            </asp:BoundField>
            <asp:TemplateField HeaderText="编辑" Visible="False">
                <ItemTemplate>
                    <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl='<%# Eval("dpid", "Modify.aspx?id={0}") %>' Text="编辑"></asp:HyperLink>
                </ItemTemplate>
                <ControlStyle Width="50px" />
            </asp:TemplateField>
            <asp:TemplateField ControlStyle-Width="50" HeaderText="删除" Visible="False">
                <ItemTemplate>
                    <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Delete"
                        Text="删除"></asp:LinkButton>
                </ItemTemplate>

                <ControlStyle Width="50px"></ControlStyle>
            </asp:TemplateField>
        </Columns>
         <PagerStyle CssClass="mypager" />
        <RowStyle HorizontalAlign="Center"></RowStyle>
    </asp:GridView>
    <table border="0" cellpadding="0" cellspacing="1" style="width: 100%;">
        <tr>
            <td style="width: 1px;"></td>
            <td align="left">
                <asp:Button ID="btnDelete" runat="server" Text="删除" OnClick="btnDelete_Click" />
            </td>
        </tr>
    </table>
</asp:Content>
<%--<asp:Content ID="Content3" ContentPlaceHolderID="ContentPlaceCheckright" runat="server">
</asp:Content>--%>
